package com.lill.org.service.impl;

import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.lill.common.component.util.IdUtil;
import com.lill.org.dao.IRegionDao;
import com.lill.org.model.RegionModel;
import com.lill.org.service.IRegionService;

/**
 * 大区管理Service实现类
 *
 * @author lill
 * @date 2019-04-24 15:25:16
 */
@Service("com.lill.org.service.impl.RegionServiceImpl")
public class RegionServiceImpl implements IRegionService {
    @Autowired
    private IRegionDao regionDao;

    public RegionModel queryObject(String id) {
        return regionDao.queryObject(id);
    }

    public List<RegionModel> queryList(Map<String, Object> map) {
        return regionDao.queryList(map);
    }

    public int queryTotal(Map<String, Object> map) {
        return regionDao.queryTotal(map);
    }

    public int save(RegionModel orgRegion) {
        orgRegion.setId(IdUtil.createIdbyUUID());
        return regionDao.save(orgRegion);
    }

    public int update(RegionModel orgRegion) {
        return regionDao.update(orgRegion);
    }

    public int delete(String id) {
        return regionDao.delete(id);
    }

    public int deleteBatch(String[] ids) {
        return regionDao.deleteBatch(ids);
    }
    
	public int deleteLogicByMap(Map<String, Object> map) {
		return regionDao.deleteLogicByMap(map);
	}
}
